Introduce canonicalization library for Windows subst drives#22129
Open
jketema wants to merge 5 commits into
Open
Introduce canonicalization library for Windows subst drives#22129jketema wants to merge 5 commits into
subst drives#22129jketema wants to merge 5 commits into
Conversation
jketema
force-pushed
the
jketema/subst-fix
branch
from
July 6, 2026 17:09
ff4372b to
8b2ab6e
Compare
jketema
force-pushed
the
jketema/subst-fix
branch
4 times, most recently
from
July 7, 2026 15:23
ef25e44 to
5d4429c
Compare
subst drives
jketema
force-pushed
the
jketema/subst-fix
branch
from
July 20, 2026 12:50
5d4429c to
b13df1f
Compare
jketema
marked this pull request as ready for review
July 21, 2026 11:43
Contributor
There was a problem hiding this comment.
Pull request overview
Adds Windows subst drive canonicalization to Go and Java/Kotlin extraction paths.
Changes:
- Loads and invokes
canonicalize.dllfrom Go and Java. - Adds the Go Windows-system dependency and Bazel wiring.
- Updates cross-language integration expectations for canonical paths.
Show a summary per file
| File | Description |
|---|---|
MODULE.bazel |
Exposes the Go Windows dependency. |
go/extractor/extractor.go |
Resolves subst paths during normalization. |
go/extractor/util/subst_windows.go |
Implements Windows DLL integration. |
go/extractor/util/subst_other.go |
Adds the non-Windows no-op. |
go/extractor/util/BUILD.bazel |
Builds platform-specific resolver sources. |
go/extractor/go.mod |
Adds x/sys. |
go/extractor/go.sum |
Records dependency checksums. |
java/kotlin-extractor/src/main/java/com/semmle/util/files/SubstResolver.java |
Adds Java native resolution. |
java/kotlin-extractor/src/main/java/com/semmle/util/files/FileUtil.java |
Applies resolution during canonicalization. |
go/ql/integration-tests/subst/file.expected |
Updates Go expected paths. |
java/ql/integration-tests/java/subst/file.expected |
Updates Java/Kotlin expected paths. |
javascript/ql/integration-tests/subst/file.expected |
Updates JavaScript expected paths. |
python/ql/integration-tests/subst/file.expected |
Updates Python expected paths. |
ruby/ql/integration-tests/subst/file.expected |
Updates Ruby expected paths. |
rust/ql/integration-tests/subst/file.expected |
Updates Rust expected paths. |
csharp/ql/integration-tests/windows/subst/file.expected |
Updates C# expected paths. |
Review details
- Files reviewed: 15/16 changed files
- Comments generated: 2
- Review effort level: Medium
Comment on lines
+31
to
+39
| p, err := d.FindProc("resolve_subst") | ||
| if err != nil { | ||
| return | ||
| } | ||
| f, _ := d.FindProc("resolve_subst_free") | ||
| dll = d | ||
| procResolve = p | ||
| procFree = f | ||
| available = true |
| return f; | ||
| } | ||
|
|
||
| String resolved = nativeResolveSubst(path.substring(0, 3)); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
See internal PR for a full explanation.